<!DOCTYPE html>
<html lang="zh-CN" xmlns:th="http://www.thymeleaf.org">
<head th:replace="common/competition-common ::  common_head(~{::link},~{::script})">
    <meta charset="utf-8">
    <link href="/styles/mall/index.css" rel="stylesheet">
    <script src="/javascript/mall/index.js" type="text/javascript"></script>
    <link href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.5.2/css/bootstrap.min.css" rel="stylesheet">
    <script type="text/javascript">
        function F_Open_dialog() {
            document.getElementById("btn_file").click();
        }
    </script>
    <style>
        .form-row {
            margin-bottom: 1rem;
        }

        .form-group {
            margin-bottom: 1rem;
        }
    </style>
</head>
<body>
<div th:replace="common/competition-common::mall-header"></div>
<div th:replace="common/competition-common::competition-sidebar"></div>
<div class="mall-body" style="margin-right: 50px">
    <div class="carousel slide home-banner" id="homeBanner">

        <form method="post">
            <input id="shipping-address-id" name="id" type="hidden" value=""/>
            <div class="modal-body">
                <div class="form-row mb-3">
                    <div class="form-group col-md-5">
                        <label class="col-form-label" for="heldLastTime"><i class="bi bi-filetype-jpg"></i>赛事图片</label>
                        <img th:src="${dto.getEventpictures()}" width="500" height="300"  class="goods-image"/>
                    </div>
                    <div class="col-md-2"></div> <!-- 增加空白列 -->
                    <div class="form-group col-md-5">
                        <label class="col-form-label" for="heldLastTime"><i class="bi bi-filetype-jpg"></i>赛事logo</label>
                        <img  class="card-title" th:src="${dto.getComlogo()}" width="500" height="300"/>
                    </div>
                </div>

                <div class="form-row mb-3">
                    <div class="form-group col-md-5">
                        <label class="col-form-label" for="eventName"><i class="bi bi-award-fill"></i>赛事名称</label>
                        <input class="form-control" id="eventName" name="province" readonly
                               th:value="${dto.getComname()}">
                    </div>
                    <div class="col-md-2"></div> <!-- 增加空白列 -->
                    <div class="form-group col-md-5">
                        <label class="col-form-label" for="eventInfo"><i class="bi bi-clipboard2"></i>赛事简介</label>
                        <input class="form-control" id="eventInfo" name="city" readonly
                               th:value="${dto.getComprofile()}">
                    </div>
                </div>

                <div class="form-row mb-3">
                    <div class="form-group col-md-5">
                        <label class="col-form-label" for="competitionPurpose"><i class="bi bi-bookmark-fill"></i>赛事宗旨</label>
                        <input class="form-control" id="competitionPurpose" name="district" readonly
                               th:value="${dto.getCompurpose()}">
                    </div>
                    <div class="col-md-2"></div> <!-- 增加空白列 -->
                    <div class="form-group col-md-5">
                        <label class="col-form-label" for="otherDescription">其他说明</label>
                        <input class="form-control" id="otherDescription" name="addrType" readonly
                               th:value="${dto.getComother()}">
                    </div>
                </div>

                <div class="form-row mb-3">
                    <div class="form-group col-md-5">
                        <label class="col-form-label" for="sponsor"><i class="bi bi-incognito"></i>赞助商</label>
                        <input class="form-control" id="sponsor" name="addrType" readonly
                               th:value="${dto.getSponsor()}">
                    </div>
                    <div class="col-md-2"></div> <!-- 增加空白列 -->
                    <!--                    <div class="form-group col-md-5">-->
                    <!--                        <label for="heldLastTime" class="col-form-label"></label>-->
                    <!--                        <input class="form-control" id="heldLastTime" name="addrType" th:value="${dto.getLastest()}">-->
                    <!--                    </div>-->
                    <div class="form-group col-md-5">
                        <label class="col-form-label" for="heldLastTime"><i class="bi bi-clock-history"></i>最近一次比赛</label>
                        <input class="form-control" id="heldLastTime" name="addrType" readonly
                               th:value="'第'+${dto.getLastest()}+'届比赛'">
                    </div>
                </div>

                <div class="form-row mb-3">
                    <div class="form-group col-md-5">
                        <label class="col-form-label" for="eventNumber"><i class="bi bi-bookmark-heart"></i>赛事编号</label>
                        <input class="form-control" id="eventNumber" name="eventNumber" readonly
                               th:value="${dto.getComid()}">
                    </div>
                </div>

            </div>
            <div class="col-lg-12" th:if="${match.matchid!=-1}">
                <a th:href="${'/competition/match-details?id='+match.getMatchid()}">
                    <div class="card">
                        <img class="goods-image" width="1250" height="500" th:src="${match.getPoster()}" />
                        <div class="card-body">
                            <h5 class="card-title" th:text="'第'+${match.number}+'届'+${match.getComname()}"></h5>
                            <p class="card-text"
                               th:text="'比赛时间：'+${#dates.format(match.getStartdate(), 'yyyy-MM-dd')}"></p>
                        </div>
                    </div>
                </a>
            </div>
        </form>
        <div th:replace="common/competition-common::mall-footerWithoutsidebar"></div>
    </div>
</div>

<script src="https://code.jquery.com/jquery-3.5.1.slim.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.9.2/dist/umd/popper.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@4.5.2/dist/js/bootstrap.min.js"></script>

</body>
</html>
